/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package admin;

/**
 *
 * @author Aluno
 */
public class Principal extends javax.swing.JFrame {

    /**
     * Creates new form Principal
     */
    public Principal() {
        initComponents();
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jMenuItem1 = new javax.swing.JMenuItem();
        jMenuItem2 = new javax.swing.JMenuItem();
        jMenuBar2 = new javax.swing.JMenuBar();
        jMenu2 = new javax.swing.JMenu();
        jMenu3 = new javax.swing.JMenu();
        jMenuBar3 = new javax.swing.JMenuBar();
        jMenu4 = new javax.swing.JMenu();
        jMenu5 = new javax.swing.JMenu();
        jMenuBar4 = new javax.swing.JMenuBar();
        jMenu6 = new javax.swing.JMenu();
        jMenu7 = new javax.swing.JMenu();
        jMenuBar1 = new javax.swing.JMenuBar();
        jMenu1 = new javax.swing.JMenu();
        mnuPessoaL = new javax.swing.JMenuItem();
        mnuPessoaG = new javax.swing.JMenuItem();
        jMenu8 = new javax.swing.JMenu();
        mnuCidadeL = new javax.swing.JMenuItem();
        mnuCidadeG = new javax.swing.JMenuItem();

        jMenuItem1.setText("jMenuItem1");

        jMenuItem2.setText("jMenuItem2");

        jMenu2.setText("File");
        jMenuBar2.add(jMenu2);

        jMenu3.setText("Edit");
        jMenuBar2.add(jMenu3);

        jMenu4.setText("File");
        jMenuBar3.add(jMenu4);

        jMenu5.setText("Edit");
        jMenuBar3.add(jMenu5);

        jMenu6.setText("File");
        jMenuBar4.add(jMenu6);

        jMenu7.setText("Edit");
        jMenuBar4.add(jMenu7);

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);

        jMenu1.setText("Pessoa");

        mnuPessoaL.setText("Listar");
        mnuPessoaL.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mnuPessoaLActionPerformed(evt);
            }
        });
        jMenu1.add(mnuPessoaL);

        mnuPessoaG.setText("Gerenciar");
        mnuPessoaG.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mnuPessoaGActionPerformed(evt);
            }
        });
        jMenu1.add(mnuPessoaG);

        jMenuBar1.add(jMenu1);

        jMenu8.setText("Cidade");

        mnuCidadeL.setText("Listar");
        mnuCidadeL.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mnuCidadeLActionPerformed(evt);
            }
        });
        jMenu8.add(mnuCidadeL);

        mnuCidadeG.setText("Gerenciar");
        mnuCidadeG.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mnuCidadeGActionPerformed(evt);
            }
        });
        jMenu8.add(mnuCidadeG);

        jMenuBar1.add(jMenu8);

        setJMenuBar(jMenuBar1);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 389, Short.MAX_VALUE)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 298, Short.MAX_VALUE)
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    private void mnuPessoaLActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mnuPessoaLActionPerformed
        pessoaListar telalistarp = new pessoaListar();
        //Configuração para fechar apenas a tela atual quando clicar no botão de fechar
        telalistarp.setDefaultCloseOperation(DISPOSE_ON_CLOSE);
        telalistarp.setVisible(true);
    }//GEN-LAST:event_mnuPessoaLActionPerformed

    private void mnuPessoaGActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mnuPessoaGActionPerformed
        PessoaJFrame telap = new PessoaJFrame();
        telap.setDefaultCloseOperation(DISPOSE_ON_CLOSE);
        telap.setVisible(true);
    }//GEN-LAST:event_mnuPessoaGActionPerformed

    private void mnuCidadeLActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mnuCidadeLActionPerformed
        cidadeListar telalistar = new cidadeListar();
        telalistar.setDefaultCloseOperation(DISPOSE_ON_CLOSE);
        telalistar.setVisible(true);
    }//GEN-LAST:event_mnuCidadeLActionPerformed

    private void mnuCidadeGActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_mnuCidadeGActionPerformed
        CidadeJFrame telac = new CidadeJFrame();
        telac.setDefaultCloseOperation(DISPOSE_ON_CLOSE);
        telac.setVisible(true);
    }//GEN-LAST:event_mnuCidadeGActionPerformed

    /**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(Principal.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(Principal.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(Principal.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(Principal.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                new Principal().setVisible(true);
            }
        });
    }

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JMenu jMenu1;
    private javax.swing.JMenu jMenu2;
    private javax.swing.JMenu jMenu3;
    private javax.swing.JMenu jMenu4;
    private javax.swing.JMenu jMenu5;
    private javax.swing.JMenu jMenu6;
    private javax.swing.JMenu jMenu7;
    private javax.swing.JMenu jMenu8;
    private javax.swing.JMenuBar jMenuBar1;
    private javax.swing.JMenuBar jMenuBar2;
    private javax.swing.JMenuBar jMenuBar3;
    private javax.swing.JMenuBar jMenuBar4;
    private javax.swing.JMenuItem jMenuItem1;
    private javax.swing.JMenuItem jMenuItem2;
    private javax.swing.JMenuItem mnuCidadeG;
    private javax.swing.JMenuItem mnuCidadeL;
    private javax.swing.JMenuItem mnuPessoaG;
    private javax.swing.JMenuItem mnuPessoaL;
    // End of variables declaration//GEN-END:variables
}
